<template>
	<view class="p30">
		<view class="p30 bg-fff radius10">
			<view class="">请描述你遇到的问题</view>
			<u-input type="textarea" v-model="form.content" :clearable="false" class="mt20" height="300" maxlength="240"
				placeholder="留下您宝贵的意见，我们第一时间看到会采取相应的措施，进行更优质的更新，给您带来更便捷的体验。">
			</u-input>
			<view class="flex row-right">
				<view class="">{{form.content.length}}/240</view>
			</view>
		</view>
		<view class="p30 bg-fff radius10 mt20">
			<view class="mb20">联系方式</view>
			<u-input v-model="form.mobile" :clearable="false" placeholder="请输入你的联系方式" />
		</view>
		<view class="pf bg-fff p30 w-max left0 bottom0">
			<u-button shape="circle" type="warning" ripple @click="submit">提交</u-button>
		</view>
	</view>
</template>

<script>
	export default {
		data() {
			return {
				form: {
					content: '',
					mobile:'',
				}
			};
		},
		methods: {
			submit() {
				if (!this.form.content) return this.$msg('请输入内容')
				this.$request('/master/personal/feedback', this.form).then(res => {
					this.$msg(res.msg)
					setTimeout(uni.navigateBack, 1000)
				})
			},
		}
	}
</script>

<style lang="scss">

</style>
